<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2016/7/21
  Time: 9:39
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>login</title>
</head>
<body>
<form action="UserLoginServlet" method="post">
    username:<input type="text" value="<%= null == request.getAttribute("username") ? "" : request.getAttribute("username")%>"
    name="username"><br>
    password:<input type="text" name="password"><br>
    authority:
    <select name="authority">
        <option value="1" <%="1".equals(request.getAttribute("authority")) ? "selected = selected" : ""%>>common user</option>
        <option value="2" <%="2".equals(request.getAttribute("authority")) ? "selected = selected" : ""%>>administrator</option>
    </select>
    <br>
    <input type="submit">

</form>
</body>
</html>
